package com.wmx.newspushmonitor;

import android.app.FragmentManager;
import android.app.FragmentTransaction;

import com.wmx.newspushmonitor.base.BaseSimpleTitleHttpActivity;
import com.wmx.newspushmonitor.databinding.ActivitySettingsBinding;


public class SettingsActivity extends BaseSimpleTitleHttpActivity<ActivitySettingsBinding> {

    @Override
    public void setContent() {
        setContentView(R.layout.activity_settings);
    }

    @Override
    public void initView() {
        mActionBarHelper.setTitle("设置");
        FragmentManager fragmentManager = getFragmentManager();
        FragmentTransaction fragmentTransaction = fragmentManager.beginTransaction();
        fragmentTransaction.replace(R.id.preferences_fragment, new SettingsFragment());
        fragmentTransaction.commit();
    }

    @Override
    public void onResume() {
        super.onResume();
        GlobalConfig.mIsSettingMode = true;
    }

    @Override
    public void onStop() {
        super.onStop();
        GlobalConfig.mIsSettingMode = false;
    }
}
